{% extends "index.html" %}
{% load adminmedia %}

{% block extrascripts2 %}
<script type="text/javascript" src="/admin/jsi18n/"></script>
<script type="text/javascript" src="{% admin_media_prefix %}js/core.js"></script>
<script type="text/javascript" src="{% admin_media_prefix %}js/admin/CollapsedFieldsets.js"></script>
{% endblock %}
{% block extrastyles %}
<link rel="stylesheet" type="text/css" href="/media/filebrowser/css/filebrowser.css" />
{% if query.pop %}
<style type="text/css">
#header { display: none; }
.breadcrumbs { display: none; }
</style>
{% endif %}
{% endblock %}


{% block content %}
{% if query.pop %}<div class="fb_breadcrumbs">{{ breadcrumbs }}</div>{% endif %}
<div id="content-main">
    <form enctype="multipart/form-data" action="?action=upload&{{ query.pop }}" method="post" name="FileForm">
    <div>
        {% if error_list %}
        <p class="errornote">
            {% for error in error_list %}
            {{ error.0 }}<br />
            {% endfor %}
        </p>
        {% endif %}
        <div style="float:left;width:60%;">
	        <div class="fieldset" style="margin-right:10px;">
	        	<h1>Seleziona i files da caricare</h1>
		        <div class="form-row">
		            <label for="id_imageupload_file">"File" 1:</label> 
		            <input type="file" id="id_imageupload_file" class="vFileUploadField" name="file" /><input type="hidden" id="id_imageupload" name="imageupload" value="" />
		        </div>
		        
		        <div class="form-row">
		            <label for="id_imageupload_file">"File" 2:</label> 
		            <input type="file" id="id_imageupload_file" class="vFileUploadField" name="file" /><input type="hidden" id="id_imageupload" name="imageupload" value="" />
		        </div>
		        
		        <div class="form-row">
		            <label for="id_imageupload_file">"File" 3:</label> 
		            <input type="file" id="id_imageupload_file" class="vFileUploadField" name="file" /><input type="hidden" id="id_imageupload" name="imageupload" value="" />
		        </div>
		        
		        <div class="form-row">
		            <label for="id_imageupload_file">{"File" 4:</label> 
		            <input type="file" id="id_imageupload_file_4" class="vFileUploadField" name="file" /><input type="hidden" id="id_imageupload" name="imageupload" value="" />
		        </div>
		        
		        <div class="form-row">
		            <label for="id_imageupload_file">{"File" 5:</label> 
		            <input type="file" id="id_imageupload_file" class="vFileUploadField" name="file" /><input type="hidden" id="id_imageupload" name="imageupload" value="" />
		        </div>
	        </div>
        </div>
        
        <div style="float:left;width:40%;">
	        <div class="fieldset">
		        <h1>Help</h1>
		        <div class="form-row" >
		            {% for extension in settings_var.EXTENSIONS.items %}
		            {% ifnotequal extension.0 'Folder' %}
		            <label for="id_body" class="required">{% if forloop.first %}"Allowed":{% else %}&nbsp;{% endif %}</label> 
		            <p>{{ extension.0 }} ({{ extension.1|join:", " }})</p>
		            {% endifnotequal %}
		            {% endfor %}
		        </div>
		        <div class="form-row" >
		            <label for="id_body" class="required">"Max. Filesize":</label> 
		            <p class="help">{{ settings_var.MAX_UPLOAD_SIZE }}</p>
		        </div>
		    </div>
		</div>
	    
        <div class="submit-row">
            <input type="submit" value="Upload" class="default" />
        </div>
    </div>
    </form>
    
</div>
{% endblock %}
